#pragma once
#include "TPColorBase.h"
class CTPGradientCenter : public CTPColorBase
{
public:
	CTPGradientCenter(void);
	~CTPGradientCenter(void);
public:
	virtual BOOL FillColor(LPVOID pColorData, BYTE* & pBuffer, int nWidth, int nHeight, eBufferFormat eFormat) ;
	virtual int	 SaveColorToBuffer(LPVOID pColorDef, LPVOID	lpBuffer, int nLength) ;
	virtual int	 LoadColorFromBuffer(LPVOID hColor,LPVOID	lpBuffer,int nLength) ;
private:
	BOOL		FillInCMethod(LPVOID pColorData, BYTE* & pBuffer, int nWidth, int nHeight, eBufferFormat eFormat) ;
	float		CalcLength(int nWidth, int nHeight, float fCenterX, float fCenterY);
	
};
